<template>
	<div id="meal_fee_log" class="dialog animated" :class="open? 'fadeIn':'fadeOut'" v-show="show">
		<div class="panel animated" :class="open? 'zoomIn':''">
			<div class="title">
				更新日志
				<div class="close" @click="cancel()"></div>
			</div>
			<div class="form">
				<table class="table" cellspacing="0">
					<thead class="thead">
						<tr>
							<td style="width: 3rem;">更新日期</td>
							<td style="width: 6rem;">更新内容</td>
							<td style="width: 2rem;">操作人</td>
						</tr>
					</thead>
					<tbody class="tbody">
						<tr v-for="item in logList">
		  					<td>{{item.updateTime}}</td>
		  					<td style="text-align: left;">{{item.content}}</td>
		  					<td>{{item.createUserName}}</td>
		  				</tr>
					</tbody>
				</table>
			</div>
		</div>
	</div>
</template>

<script>
var vm,dict;
export default {
	data : function() {
		return {
			show : false,
			open : false,
			logList: []
		}
	},
	methods : {
		init : function(id) {
			vm.show = true;
			vm.open = true;
			
			api.mealFeeLog({mealsId: id}).then(function(data){
				vm.logList = data.list;
			});
			
		},
		cancel : function() {
			vm.open = false;
			setTimeout(function() {
				vm.show = false;
			},500);
		},
	},
	created : function() {
		vm = this;
		dict = tool.getItem(lsKey.dict,true);
		
	}
}

</script>

<style scoped src="@/style/module/dialog.css"></style>
<style scoped src="@/style/module/table.css"></style>
<style scoped>

	.panel {
		width: 9rem;
	}
	.form {
		padding: 0 0.3rem 0.5rem 0.3rem;
		color: #666666;
	}
</style>